import { deleteRequest, downPostRequest, getRequest, postRequest, putRequest } from '@/common/config/request';
import { SYS_BASE_URL } from "@/common/constant/Const";

export const getMenuBtnByParentId = (data) =>{
    return getRequest(SYS_BASE_URL + "/api/menu/getMenuBtn/" + data);
}

export const menuListPaging = (data) =>{
    return postRequest(SYS_BASE_URL + "/api/menu/list-paging",data);
}

export const createMenu = (data) =>{
    return postRequest(SYS_BASE_URL + "/api/menu/save",data);
}

export const updateMenu = (data) =>{
    return postRequest(SYS_BASE_URL + "/api/menu/update",data);
}

export const deleteMenu = (data) =>{
    return deleteRequest(SYS_BASE_URL + "/api/menu/delete",data);
}